
exports.install = function (Vue, options) {
  Vue.prototype.MImage = function (imagePath) {
    if (imagePath) {
      if (imagePath.includes('http')) {
        return imagePath
      } else {
        // return process.env.BASE_API + imagePath
        return 'https://www.sx-cc.com' + imagePath
      }
    } else {
      return 'https://cdn.vuetifyjs.com/images/cards/desert.jpg'
    }
  }
  Vue.prototype.MOverview = function (rawContent, length = 100) {
    if (rawContent) {
      const content = rawContent.replace(/<\/?.+?>/g, '')
      return content.slice(0, length)
    } else {
      return ''
    }
  }
}
